﻿using com.uplus.snowleopardframework.Attributes;
using SqlSugar;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Threading.Tasks;
using WebApi.Bill.Biz;

namespace WebApi.Models
{
    /// <summary>
    /// 邮件模板
    /// </summary>
    [SugarTable("TbEmailTemplate")]
    [DisplayName("邮件模板")]
    public class EmailTemplateModel
    {

        [DisplayName("主键")]
        [SugarColumn(IsNullable = false, ColumnName = "pkCode", IsPrimaryKey = true, ColumnDataType = "varchar", Length = 2, ColumnDescription = "主键")]
        public string Code { get; set; }

        [DisplayName("客户编码")]
        [SugarColumn(IsNullable = true, ColumnName = "fkCust", ColumnDataType = "varchar", Length = 4, ColumnDescription = "客户表外键")]
        public string FkCust { get; set; }

        [ControlType(Type = ControlTypeAttribute.Types.Text, PlaceHolder = "请输入邮件内容", IsDisabled = false)]
        [DisplayName("邮件内容")]
        [SugarColumn(IsNullable = true, ColumnName = "sEmailContent", ColumnDataType = "text", ColumnDescription = "邮件内容")]
        public string SEmailContent { get; set; }

        [ControlType(Type = ControlTypeAttribute.Types.Text, PlaceHolder = "请输入邮件模版英文名", IsDisabled = false)]
        [DisplayName("邮件模版")]
        [SugarColumn(IsNullable = true, ColumnName = "sEmailTemplate", ColumnDataType = "varchar", Length = 32, ColumnDescription = "邮件模版")]
        public string SEmailTemplate { get; set; }

        [ControlType(Type = ControlTypeAttribute.Types.Text, PlaceHolder = "请输入邮件模版名称", IsDisabled = false)]
        [DisplayName("邮件模版名称")]
        [SugarColumn(IsNullable = true, ColumnName = "sTemplateName", ColumnDataType = "varchar", Length = 32, ColumnDescription = "邮件模版名称")]
        public string STemplateName { get; set; }

        [DisplayName("操作人")]
        [SugarColumn(IsNullable = true, ColumnName = "sOperator", ColumnDataType = "varchar", Length = 50, ColumnDescription = "操作人")]
        public string SOperator { get; set; }

        [DisplayName("操作时间")]
        [SugarColumn(IsNullable = true, ColumnName = "tOperate", ColumnDataType = "datetime", ColumnDescription = "操作时间")]
        public DateTime? TOperate { get; set; }

        [DisplayName("创建时间")]
        [SugarColumn(IsNullable = true, ColumnName = "tCreate", ColumnDataType = "datetime", ColumnDescription = "创建时间")]
        public DateTime? TCreate { get; set; }
    }
}
